view verification.py @ 2:d77ff06f5dc9 draft default tip

planemo upload for repository https://github.com/brsynth/galaxytools/tree/main/tools commit d8cc8b87fdb0374745b5420f2da7f08ae905c222-dirty
author tduigou
date Wed, 16 Jul 2025 14:51:52 +0000
parents 178d068648f4
children
line wrap: on
line source

from sqlalchemy import create_engine, text

db_uri = "postgresql://postgres:RK17@localhost:5432/test_fragments_db"  # adapt with your URI's DB
engine = create_engine(db_uri)

with engine.connect() as conn:
    result = conn.execute(text("""
        SELECT fragment, sequence, annotation
        FROM sample
        ORDER BY fragment
    """))

    print("Full contents of fragments in DB:\n")
    for row in result:
        print(f" Fragment: {row.fragment}")
        print(" Sequence:")
        print(row.sequence)
        print("\n Annotation:")
        print(row.annotation)
        print("-" * 80)