Dashboard 2 CRUD node

I've give it to you this screenshot this afternoon

Is there a problem with it ?

Thanks Steve,
I will read it carefully...
Do you think that it's better to scope it with @flowfuse (for easier search) or with @cyprien ?

The json keys are not the same. Perhaps you can use sql directive "AS" to change the keys ? Could you post me your query ?

sure
msg.topic = SELECT COLUMN_NAME, DATA_TYPE, CHARACTER_MAXIMUM_LENGTH, IS_NULLABLE FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME = '${msg.tableName}' AND ( (COLUMN_NAME = 'Schedule' AND DATA_TYPE = 'varchar') OR (COLUMN_NAME = 'Lines' AND DATA_TYPE = 'varchar') OR (COLUMN_NAME = 'Scrap' AND DATA_TYPE = 'int') OR (COLUMN_NAME = 'Rework' AND DATA_TYPE = 'int') OR (COLUMN_NAME = 'Duration' AND DATA_TYPE = 'int') OR (COLUMN_NAME = 'Countermeasure' AND DATA_TYPE = 'varchar') ) ;
msg.action = 'pragma';
return msg;

Could you test by changing the begining of your query ?
Not sure that your WHERE clause is correct, why don't you return all your fields ?

SELECT COLUMN_NAME AS name, DATA_TYPE AS type, CHARACTER_MAXIMUM_LENGTH, IS_NULLABLE FROM

msg.topic = SELECT COLUMN_NAME AS name, DATA_TYPE AS type, CHARACTER_MAXIMUM_LENGTH, IS_NULLABLE FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME = '${msg.tableName}' AND ( (COLUMN_NAME = 'Schedule' AND DATA_TYPE = 'varchar') OR (COLUMN_NAME = 'Lines' AND DATA_TYPE = 'varchar') OR (COLUMN_NAME = 'Scrap' AND DATA_TYPE = 'int') OR (COLUMN_NAME = 'Rework' AND DATA_TYPE = 'int') OR (COLUMN_NAME = 'Duration' AND DATA_TYPE = 'int') OR (COLUMN_NAME = 'Countermeasure' AND DATA_TYPE = 'varchar') );
msg.action = 'pragma';
return msg;
like this?

Yes ! like this !

i obtain this,


but in the dashbord ii have this:

I think best start off on the right path & use scope but Not FlowFuse. That's our company name :sweat_smile:

Use you're own scope (whatever you chose).

+1 here, the idea of the scoping is to link it to the author. Anything we build, we use @flowfuse, any third-party/community pieces should be scoped to the relevant author.

Are you on MS SQL ? On sqlite, i use INSERT INTO query and it auto increment the ID, so, i don't specify it.
I think that it's the same on MS SQL, but i'm not sure... Anyway, it's a database configuration problem.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.