SHAFURDEEN

Datalogic scanner data retreive

7 posts in this topic

Hi members of the forum , I have a problem that need to be solve . 

Need some support in data transfer from Barcode – PLC – SQL.

Below is the situation.

Currently now in each material we use in machine there will have 3 information of barcode to be capture. How can the PLC detect all 3 information and send it to SQL as one data.

E.g: material cage over mould

Info that ned to be capture:

Product ID No:   BM01MFG0001-01-B

Work order No: WO151885

Qty:                     300

All three information can be send as BM01MFG0001-01-B,WO151885,300 and how can I send it all to get there to our SQL?

Currently now I'm using NJ series and NJ-DB.

Question : What need to be change to make all above data to be send to SQL column Cage_Batch_No

Below is the current  RUNG that we have.

 

What need to be edit at below RUNG to make it able to collect all 3 data and send as 1 data to the MOVE location.

PLC.jpg

PLC2.jpg

Share this post


Link to post
Share on other sites

I cannot see the pictures for some reason.  But, basically you need to parse the string into the three pieces of data and then convert each of the three to the appropriate data type (that matches the database).  

Perhaps:

Product ID as STRING

Work order as STRING

Qty as UINT

 

Then use the DB commands to send the data.

1 person likes this

Share this post


Link to post
Share on other sites

By the way, I deleted your other duplicate post.

Share this post


Link to post
Share on other sites

Hi Michael

Here I attach the ladder for your view.

 

Perviously we only scan 1 info and now we wanted to scan info in a row and capture it as the data.

Info that ned to be capture:

Product ID No:   BM01MFG0001-01-B

Work order No: WO151885

Qty:                     300

All data capture hope to capture as shown: BM01MFG0001-01-B,WO151885,300

 

Capture.JPG.fc618b5bb4c53b444cfd5fd81b18

 

The new data we need to transfer to Rung 5 as where EQascii number 4 is where the data need to be install and transfer to NJ-DB.

Capture2.JPG.ad85a59345fd701b4e67a659213

Capture3.JPG.628b76da8b35a8beab4caff3c04

 

Can I write the code as above , current I just wrote 2 data info and move it to DB.

And help to show me some sample code ifyou have one.

Capture4.JPG

Edited by SHAFURDEEN
1 person likes this

Share this post


Link to post
Share on other sites

Hi Micheal

Can you help to show me some sample rung for me to this project? Really appreciate it.

 

Share this post


Link to post
Share on other sites

I am sorry, but I do not understand what you are asking....

 

Share this post


Link to post
Share on other sites

Hi Micheal

 

As per previous reply you suggest me as below:

Product ID as STRING

Work order as STRING

Qty as UINT

 

Can you show me a sample of rung on how to make product ID and  Work order as a String , while Qty as a UINT.

and how I can send above data as Product ID,Work,Qty to the next Function block.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now