Skip to content

ddl2cpp command line argument for custom types#491

Merged
rbock merged 4 commits into
rbock:mainfrom
CJCombrink:feature/extend_datatype_csv_file
Jun 22, 2023
Merged

ddl2cpp command line argument for custom types#491
rbock merged 4 commits into
rbock:mainfrom
CJCombrink:feature/extend_datatype_csv_file

Conversation

@CJCombrink
Copy link
Copy Markdown
Contributor

  • Updated the ddl2cpp script to allow custom/extended types through external csv file
  • Had to re-order the script to allow the command line to be parsed before setting up the parser
  • Updated README

- Updated the ddl2cpp script to allow custom/extended types through external csv file
- Had to re-order the script to allow the command line to be parsed before setting up the parser
- Updated README
@rbock
Copy link
Copy Markdown
Owner

rbock commented Jun 15, 2023

This looks pretty nice, thanks for the new PR.

Can you add a test in the tests/scripts directory?

@CJCombrink
Copy link
Copy Markdown
Contributor Author

I am planning to add a test yes.
I unfortunately could not get to adding one before I had to go to work today.
We also have a public holiday tomorrow so might only attempt to add a test on Monday

@rbock
Copy link
Copy Markdown
Owner

rbock commented Jun 16, 2023

No worries, I did not mean to rush you :-)

@CJCombrink
Copy link
Copy Markdown
Contributor Author

CJCombrink commented Jun 19, 2023

@rbock Do you have some suggestion for a test?

Did you have a separate test script in mind or do you suggest a type of test that gets included with the existing --test command line argument?

I think I found the location and method, will implement something

- Script test only for now
Comment thread tests/scripts/CMakeLists.txt Outdated
- Firs a negative test
- Last a positive test and compile test against the generated output
Copy link
Copy Markdown
Owner

@rbock rbock left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the creating the test! I have one comment, but otherwise, this looks very good to me.

Comment thread tests/scripts/ddl2cpp_sample_good_custom_type.sql
- Ensure built in types still work
- Check capitilisation
- Ensure more than one custom works
- Check type with spaces
@rbock
Copy link
Copy Markdown
Owner

rbock commented Jun 21, 2023

Looks good to me. If you're also happy at this point, I think this is ready to be merged.

@CJCombrink
Copy link
Copy Markdown
Contributor Author

Thanks for the library and feedback.
I am happy, it can be merged.

@rbock rbock merged commit babd420 into rbock:main Jun 22, 2023
@rbock
Copy link
Copy Markdown
Owner

rbock commented Jun 22, 2023

Done :-)

@CJCombrink CJCombrink deleted the feature/extend_datatype_csv_file branch June 22, 2023 05:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants