Export specific Excel cell data

Hello guys,

Is it possible to export data from multiple specific Excel cells, from different Worksheets on the same Excel Workbook and import it into database?

Lets say that I need to get the data from A3 to A6 and B4 in WorkSheet1, plus A3 from WorkSheet2, and than to import it into 3 separate Columns in my database.

I am trying to do that using ExcelRead and SetValue, but without success.
Thanks in advance.

Hi Alex,

Yes it is possible. I’ll write a quick Example.

Dawie

Hi Alex,

Even though it’s possible, by hardcoding the Ranges, I think I see why you were struggling. The ranges cannot be assigned dynamically. I’m going to request a feature change from the development team. It would be great if the Excel Ranges are dynamic. Then your question could be done very quickly.

Dawie

Hi Dawie,

Thank you so much Dawie. Maybe you have right, dynamic range will be very ncie. When can I expect the example?

kind regards.

Cool. Will let you know as soon as I know. :slight_smile:

Thanks once again Dawie.

How can I specify ExcelRead Range to get data from all B column from second Sheet?
I tried with Sheet2!B2:B100 but seems like it cannot be done in that way?

Thank you in advance.

Excuse me for disturbing you.

Hi Alex,

Yes, there’s 2 ways to do this:

  1. You can use the name of the Sheet if you know it:

  2. You can use the number of the sheet if you don’t know the name:

Thank you so much Dawie for reply .

Now can you just show me how suppose to UPDATE statement looks like in ExecuteSQL? Beocuse I have a problem to configure it.

One more question please. I have two Lists, and trying to import into DB first item from List1 and first item from List2 in the same time (same row). After that I need to import second item from List1 and second item from List2, and further more…
Is there any way to use ForEach with parametars List1+List2 in same time, in reason to import List1[i] into Column1 and List2[i] into Column2 in same row?
I hope that you understand me:)

Thanks in advance.

Hi Alex,

I did a quick example: UsingListIndex.lsoz (3.4 KB)

You can use the “undocumented” List indexes to easily do this. This is undocumented because there may be some undesirable behaviours if you don’t manage your indexes correctly and try to get values that don’t exist. Thus just be careful.

Dawie