Symbianize Forum

Most of our features and services are available only to members, so we encourage you to login or register a new account. Registration is free, fast and simple. You only need to provide a valid email. Being a member you'll gain access to all member forums and features, post a message to ask question or provide answer, and share or find resources related to mobile phones, tablets, computers, game consoles, and multimedia.

All that and more, so what are you waiting for, click the register button and join us now! Ito ang website na ginawa ng pinoy para sa pinoy!

I need Help sa VB.NET Mysql mga expert.

xhypertazx

Novice
Advanced Member
Messages
49
Reaction score
0
Points
26
First explain ko muna mga table ko sa mysql:

table: stock_inventory
fields: stock_id (primary key), inventory_id (FK from supplies table), date_received, date_expired, type, price, stock_received, stock_left, no_days

table: supplies
fields: inventory_id (primary key), supply_name, description

table: dispense_supply
fields: dd_id (primary key), batch_id (FK from stock_inventory as stock_id), inventory_id (FK from supplies), quantity, price, date)

First task:
Paano ko po i-display sa datagridview pagnag-search ako sa textbox ng supplies either stock id or name ng supply sa stock_inventory at supplies na tables, need ko idisplay ang stock_id, inventory_id, supply_name, description, stock_left. (mysql query po)

2nd task: mag-dispense ng supply
bali babawasan ko yung stock left ng na-search ko na supply, may textbox ako kung saan kukunin ang quantity ng i-dispense. so bale ma-uupdate ang stock_inventory na table, yung stock_left nya.... and at the same time mag-iinsert ako ng new record sa table na dispense_supply ng binawas ko na supply sa stock_inventory na table. (process at mysql query)

Sana po naintindihan nyo po at maraming salamat mga programming masters!

- - - Updated - - -

Anyone po?
 
First explain ko muna mga table ko sa mysql:

table: stock_inventory
fields: stock_id (primary key), inventory_id (FK from supplies table), date_received, date_expired, type, price, stock_received, stock_left, no_days

table: supplies
fields: inventory_id (primary key), supply_name, description

table: dispense_supply
fields: dd_id (primary key), batch_id (FK from stock_inventory as stock_id), inventory_id (FK from supplies), quantity, price, date)

First task:
Paano ko po i-display sa datagridview pagnag-search ako sa textbox ng supplies either stock id or name ng supply sa stock_inventory at supplies na tables, need ko idisplay ang stock_id, inventory_id, supply_name, description, stock_left. (mysql query po)

2nd task: mag-dispense ng supply
bali babawasan ko yung stock left ng na-search ko na supply, may textbox ako kung saan kukunin ang quantity ng i-dispense. so bale ma-uupdate ang stock_inventory na table, yung stock_left nya.... and at the same time mag-iinsert ako ng new record sa table na dispense_supply ng binawas ko na supply sa stock_inventory na table. (process at mysql query)

Sana po naintindihan nyo po at maraming salamat mga programming masters!

- - - Updated - - -

Anyone po?

For task Number 1
SELECT A.stock id, B.inventory id, B.supply name, B.description, A.stock left
FROM stock inventory A
INNER JOIN supplies B
on B.inventory id = A.inventory id
 
Back
Top Bottom