Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Miles_Dyson
Contributor III
Contributor III

Question Regarding Autogenerate & External Data Sources

Hi folks,

Asking just for curiosity's sake. What is the reason why Autogenerate() field list must not contain expressions which require data from an external data source or a previously loaded table..., unless you refer to a single field value in a previously loaded table with the Peek function.

Thank you

Labels (5)
2 Solutions

Accepted Solutions
Sayed_Mannan
Creator
Creator

Autogenerate() function is used in the load statement to automatically generate data. This function is particularly useful when you need to create a table of random numbers or a range of dates.

However, the  Autogenerate() function has a key limitation, the field list must not contain expressions that require data from an external data source or a previously loaded table. This is because Autogenerate() is designed to generate data independently, without relying on external data sources or previously loaded tables.

The only exception to this rule is when you refer to a single field value in a previously loaded table with the Peek() function. The Peek() function allows you to retrieve a single field value from a previously loaded table, which can then be used in the  Autogenerate() function.

This design ensures that the Autogenerate() function can operate independently and efficiently, without the need to access external data sources or previously loaded tables. It also helps to avoid potential issues with data dependencies and ensures that the data generation process is predictable and consistent.

 

I hope this helps.

View solution in original post

Miles_Dyson
Contributor III
Contributor III
Author

Thank you, makes sense.

View solution in original post

2 Replies
Sayed_Mannan
Creator
Creator

Autogenerate() function is used in the load statement to automatically generate data. This function is particularly useful when you need to create a table of random numbers or a range of dates.

However, the  Autogenerate() function has a key limitation, the field list must not contain expressions that require data from an external data source or a previously loaded table. This is because Autogenerate() is designed to generate data independently, without relying on external data sources or previously loaded tables.

The only exception to this rule is when you refer to a single field value in a previously loaded table with the Peek() function. The Peek() function allows you to retrieve a single field value from a previously loaded table, which can then be used in the  Autogenerate() function.

This design ensures that the Autogenerate() function can operate independently and efficiently, without the need to access external data sources or previously loaded tables. It also helps to avoid potential issues with data dependencies and ensures that the data generation process is predictable and consistent.

 

I hope this helps.

Miles_Dyson
Contributor III
Contributor III
Author

Thank you, makes sense.