Zum Hauptinhalt gehen

Suche

Suche

print from sql database and write to another database

Kommentare

2 Kommentare

  • Avatar
    Xabier Clemente
    Moderator

    Hi Kardo!

    Thank you for reaching us with your query on our BarTender Community Forums.

    Have you tried using Conditional Printing? If what we need is to prevent BarTender from printing when certain fields are empty, the easiest way of achieving this would be through the use of a conditional expression. Here are some resources which I believe should prove to be of use to you, please review them as they go through the basics of Conditional Printing:


    Let us know if these were of help to you!

    0
  • Avatar
    Kardo Aia

    Hi,

    Unfortunatelly this is a different thing.

    Maybe I should try to explain better.

    I have a SQL database where I need to get serial numbers for a specific work order. The problem is they are not on the same table so query to SQL database getting the serial numbers in a work order has several inner joins.

    This is the reason I couldn't set it up as printing from database (Database connection setup under printing). Setting that up was a lot different than just sending an SQL query. And I'm even not sure if it's possible that way to input work order and then get answer from database using that method.

    What I'm doing right now:

    OnPrintJobStart (vbscript): Ask work order. Send SQL query that finds all serial numbers corresponding to that work order. I get back serial numbers. Find smallest and amount. Print them (set SN to smallest and print qty to amount). The problem with this method is that in some rare cases, a serial number might be skipped (meaning not in the database, so shouldn't be printed) and I can't acheive this right now. So I need to

    All serial numbers will be printed on different lables if that makes a difference. And the lables themselves are different, some have just SN, some also have barcode for it and some have other fields that is set on the template.

    0

Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.