Drop files here

SQL upload ( 0 ) x -

Page-related settings Click on the bar to scroll to top of page
Press Ctrl+Enter to execute query Press Enter to execute query
ascending
descending
Order:
Debug SQL
Count
Execution order
Time taken
Order by:
Group queries
Ungroup queries
Collapse Expand Show trace Hide trace Count : Time taken :
Bookmarks
Refresh
Add
No bookmarks
Add bookmark
Options
Set default





Collapse Expand Requery Edit Explain Profiling Bookmark Query failed Database : Queried time :
Untitled *
v Show/Hide tables list View in full-screen Add tables from other databases New page Open page Save page Save page as Delete pages Create table Create relationship Choose column to display Reload Help Angular links / Direct links Snap to grid v Small/Big All Toggle small/big Toggle relationship lines Export schema > Move Menu > Pin text
Number of tables: 0
v photostore cache
* key : varchar(255)
* value : mediumtext
* expiration : int(11)
v photostore cache_locks
* key : varchar(255)
* owner : varchar(255)
* expiration : int(11)
v photostore categories
* id : bigint(20) unsigned
* parent_id : bigint(20) unsigned
* image : varchar(255)
* sort_order : int(10) unsigned
* is_active : tinyint(1)
* created_at : timestamp
* updated_at : timestamp
v photostore category_translations
* id : bigint(20) unsigned
* category_id : bigint(20) unsigned
* locale : varchar(5)
* name : varchar(255)
* slug : varchar(255)
* description : text
* created_at : timestamp
* updated_at : timestamp
v photostore currencies
* id : bigint(20) unsigned
* code : varchar(3)
* name_ar : varchar(255)
* name_en : varchar(255)
* symbol : varchar(10)
* exchange_rate : decimal(18,6)
* decimal_places : tinyint(3) unsigned
* is_base : tinyint(1)
* is_active : tinyint(1)
* sort_order : int(10) unsigned
* created_at : timestamp
* updated_at : timestamp
v photostore customers
* id : bigint(20) unsigned
* name : varchar(255)
* email : varchar(255)
* phone : varchar(255)
* password : varchar(255)
* preferred_locale : varchar(5)
* preferred_currency : varchar(3)
* email_verified_at : timestamp
* remember_token : varchar(100)
* created_at : timestamp
* updated_at : timestamp
v photostore customer_addresses
* id : bigint(20) unsigned
* customer_id : bigint(20) unsigned
* label : varchar(255)
* city : varchar(255)
* address_line : varchar(255)
* phone : varchar(255)
* is_default : tinyint(1)
* created_at : timestamp
* updated_at : timestamp
v photostore expenses
* id : bigint(20) unsigned
* expense_category_id : bigint(20) unsigned
* warehouse_id : bigint(20) unsigned
* created_by : bigint(20) unsigned
* title : varchar(255)
* amount : decimal(14,2)
* expense_date : date
* attachment : varchar(255)
* notes : text
* created_at : timestamp
* updated_at : timestamp
v photostore expense_categories
* id : bigint(20) unsigned
* name_ar : varchar(255)
* name_en : varchar(255)
* is_active : tinyint(1)
* created_at : timestamp
* updated_at : timestamp
v photostore failed_jobs
* id : bigint(20) unsigned
* uuid : varchar(255)
* connection : text
* queue : text
* payload : longtext
* exception : longtext
* failed_at : timestamp
v photostore jobs
* id : bigint(20) unsigned
* queue : varchar(255)
* payload : longtext
* attempts : tinyint(3) unsigned
* reserved_at : int(10) unsigned
* available_at : int(10) unsigned
* created_at : int(10) unsigned
v photostore job_batches
* id : varchar(255)
* name : varchar(255)
* total_jobs : int(11)
* pending_jobs : int(11)
* failed_jobs : int(11)
* failed_job_ids : longtext
* options : mediumtext
* cancelled_at : int(11)
* created_at : int(11)
* finished_at : int(11)
v photostore migrations
* id : int(10) unsigned
* migration : varchar(255)
* batch : int(11)
v photostore orders
* id : bigint(20) unsigned
* order_number : varchar(255)
* customer_id : bigint(20) unsigned
* warehouse_id : bigint(20) unsigned
* created_by : bigint(20) unsigned
* source : enum('online','pos')
* status : enum('pending','processing','shipped','delivered','cancelled','refunded')
* payment_status : enum('unpaid','paid','partially_paid','refunded')
* payment_method : varchar(255)
* subtotal : decimal(14,2)
* discount_amount : decimal(14,2)
* tax_amount : decimal(14,2)
* shipping_cost : decimal(14,2)
* total : decimal(14,2)
* cost_of_goods_total : decimal(14,2)
* display_currency : varchar(3)
* display_exchange_rate : decimal(18,6)
* shipping_city : varchar(255)
* shipping_address : varchar(255)
* shipping_phone : varchar(255)
* notes : text
* created_at : timestamp
* updated_at : timestamp
v photostore order_items
* id : bigint(20) unsigned
* order_id : bigint(20) unsigned
* product_id : bigint(20) unsigned
* product_name : varchar(255)
* quantity : int(10) unsigned
* unit_price : decimal(14,2)
* unit_cost : decimal(14,2)
* total_price : decimal(14,2)
* created_at : timestamp
* updated_at : timestamp
v photostore order_item_batch
* id : bigint(20) unsigned
* order_item_id : bigint(20) unsigned
* stock_batch_id : bigint(20) unsigned
* quantity : int(10) unsigned
* unit_cost : decimal(14,2)
* created_at : timestamp
* updated_at : timestamp
v photostore password_reset_tokens
* email : varchar(255)
* token : varchar(255)
* created_at : timestamp
v photostore products
* id : bigint(20) unsigned
* sku : varchar(255)
* category_id : bigint(20) unsigned
* brand : varchar(255)
* price : decimal(14,2)
* compare_price : decimal(14,2)
* cost_price : decimal(14,2)
* weight_kg : decimal(8,3)
* track_stock : tinyint(1)
* low_stock_threshold : int(10) unsigned
* is_active : tinyint(1)
* published_at : timestamp
* created_at : timestamp
* updated_at : timestamp
* deleted_at : timestamp
v photostore product_images
* id : bigint(20) unsigned
* product_id : bigint(20) unsigned
* path : varchar(255)
* alt_text : varchar(255)
* is_primary : tinyint(1)
* sort_order : int(10) unsigned
* created_at : timestamp
* updated_at : timestamp
v photostore product_translations
* id : bigint(20) unsigned
* product_id : bigint(20) unsigned
* locale : varchar(5)
* name : varchar(255)
* slug : varchar(255)
* short_description : text
* description : longtext
* meta_title : varchar(255)
* meta_description : varchar(255)
* created_at : timestamp
* updated_at : timestamp
v photostore purchases
* id : bigint(20) unsigned
* reference_number : varchar(255)
* supplier_id : bigint(20) unsigned
* warehouse_id : bigint(20) unsigned
* created_by : bigint(20) unsigned
* status : enum('draft','ordered','received','cancelled')
* subtotal : decimal(14,2)
* discount_amount : decimal(14,2)
* tax_amount : decimal(14,2)
* shipping_cost : decimal(14,2)
* total : decimal(14,2)
* purchase_date : date
* received_date : date
* notes : text
* created_at : timestamp
* updated_at : timestamp
v photostore purchase_items
* id : bigint(20) unsigned
* purchase_id : bigint(20) unsigned
* product_id : bigint(20) unsigned
* quantity : int(10) unsigned
* unit_cost : decimal(14,2)
* total_cost : decimal(14,2)
* created_at : timestamp
* updated_at : timestamp
v photostore sessions
* id : varchar(255)
* user_id : bigint(20) unsigned
* ip_address : varchar(45)
* user_agent : text
* payload : longtext
* last_activity : int(11)
v photostore stock_batches
* id : bigint(20) unsigned
* batch_number : varchar(255)
* product_id : bigint(20) unsigned
* warehouse_id : bigint(20) unsigned
* supplier_id : bigint(20) unsigned
* purchase_id : bigint(20) unsigned
* cost_price : decimal(14,2)
* quantity_received : int(10) unsigned
* quantity_remaining : int(10) unsigned
* received_date : date
* expiry_date : date
* notes : text
* created_at : timestamp
* updated_at : timestamp
v photostore stock_movements
* id : bigint(20) unsigned
* product_id : bigint(20) unsigned
* warehouse_id : bigint(20) unsigned
* batch_id : bigint(20) unsigned
* type : enum('purchase_in','sale_out','transfer_in','transfer_out','adjustment_in','adjustment_out','return_in')
* quantity : int(11)
* unit_cost : decimal(14,2)
* reference_type : varchar(255)
* reference_id : bigint(20) unsigned
* created_by : bigint(20) unsigned
* notes : text
* created_at : timestamp
* updated_at : timestamp
v photostore suppliers
* id : bigint(20) unsigned
* name : varchar(255)
* phone : varchar(255)
* email : varchar(255)
* address : varchar(255)
* tax_number : varchar(255)
* notes : text
* is_active : tinyint(1)
* created_at : timestamp
* updated_at : timestamp
v photostore users
* id : bigint(20) unsigned
* name : varchar(255)
* email : varchar(255)
* email_verified_at : timestamp
* password : varchar(255)
* role : varchar(255)
* warehouse_id : bigint(20) unsigned
* is_active : tinyint(1)
* remember_token : varchar(100)
* created_at : timestamp
* updated_at : timestamp
v photostore warehouses
* id : bigint(20) unsigned
* name_ar : varchar(255)
* name_en : varchar(255)
* code : varchar(255)
* city : varchar(255)
* address : varchar(255)
* phone : varchar(255)
* is_default : tinyint(1)
* is_active : tinyint(1)
* created_at : timestamp
* updated_at : timestamp
Create relationship
FOREIGN KEY
on delete
on update
Delete relationship